package wuxianshua.controller;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;
import wuxianshua.pojo.Gold;
import wuxianshua.service.GoldService;

/**
 * Description:
 * Datetime:    2021/2/20   19:53
 * Author:   jianglei
 */
@Controller
public class GoldController {
    @Autowired
    private GoldService goldService;

    @ResponseBody
    @RequestMapping("/coin")
    public String insetrOne(){
        int i = goldService.insetOne();
        if(i>=1){
            return "success";
        }
        return "fail";
    }

}